import request from '@/utils/request'

export function deptTreeTable(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/dept/treeTable`,
    method: 'post',
    data: query
  })
}

export function deptTreeData(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/dept/treeData`,
    method: 'post',
    data: query
  })
}

export function deptLoad(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/dept/load`,
    method: 'get',
    params: query
  })
}

export function deptSave(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/dept/save`,
    method: 'post',
    data: query
  })
}

export function deptDelete(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/dept/delete`,
    method: 'post',
    data: query
  })
}
